/*
 * global_declarations.h
 *
 *  Created on: Jul 25, 2010
 *      Author: Ofer
 */

#ifndef GLOBAL_DECLARATIONS_H_
#define GLOBAL_DECLARATIONS_H_

#define MAX_LINE_LENGTH 256

typedef enum bool{
	false = 0, true = 1
} bool;

typedef long int64;

typedef struct {
	int size;
	char* data;
} String;


void String_print(String* str);
void String_init(String* dest, int size);
void String_copy(String* dest, char* src);
void String_n_copy(String* dest, char* src, int n);
void String_free(String* s);
void String_cat(String* dest, char* src);
void String_cat_String(String* dest, String* src);
void String_copy_string(String* dest, String* src);
void int_to_string_digit(String* dest, int i);
void char_int_to_string (String* dest, int i);
char flip_char_case(char c);
String* make_empty_string();
String* make_string_from_char_arr(char* s);
void String_reset(String* str);
bool is_number(char* s);
int64 String_to_int64(String s);
int min_int(int a, int b);
int max_int(int a, int b);
void remove_end_of_line(char* str);


#endif /* GLOBAL_DECLARATIONS_H_ */

